<%--
/**
* Copyright (c) 2000-2010 OSSR!ORG All rights reserved.
*
* This library is free software; you can redistribute it and/or modify it under
* the terms of the GNU Lesser General Public License as published by the Free
* Software Foundation; either version 2.1 of the License, or (at your option)
* any later version.
*
* This library is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
* details.
*/
--%>

<%@ include file="/html/init.jsp" %>

<portlet:defineObjects />
<liferay-theme:defineObjects />

<liferay-portlet:actionURL name="sendMessage" var="sendMessageUrl">
</liferay-portlet:actionURL>


<%
	Set<User> users = (Set<User>) request.getAttribute("availableUsers") ;
	List<Group> groups = (List<Group>) request.getAttribute("availableGroups");
	
%>

<aui:form name="sendMessage" action="<%= sendMessageUrl.toString()%>" method="post">
<aui:button-row>
	<aui:input type="hidden" name="redirectURL" value="<%= renderResponse.createRenderURL().toString() %>" />
	<input type="button" value="Back to Inbox" onclick="location.href='<%= renderResponse.createRenderURL().toString() %>&fromAction=cancel'" />
	<aui:button name="send" type="submit" value="Send Message" />
</aui:button-row>

	<aui:fieldset label="New Message">
		<aui:field-wrapper>
			<aui:input name="subject" label="Subject" type="text" size="80" maxlength="120"/>
		</aui:field-wrapper>
		<aui:field-wrapper>
			<label class="aui-field-label" for='<portlet:namespace />recipients-list'>
				Recipients (click to add/remove):
			</label>
			<div id="recipients-list" class="readonly-field" style="width: 300px; height: 20px;"></div>
			<aui:input name="recipients" label="Recipients" type="hidden" />
		</aui:field-wrapper>
		<aui:field-wrapper>
		<label class="aui-field-label" for='<portlet:namespace />message'>
			Message:
		</label>
		<liferay-ui:input-editor editorImpl="<%= EDITOR_WYSIWYG_IMPL_KEY %>" name="message" />
		</aui:field-wrapper>
	</aui:fieldset>
</aui:form>

<script language="javascript" type="text/javascript">
	function <portlet:namespace />initEditor(){
		
	}
</script>

<%!
public static final String EDITOR_WYSIWYG_IMPL_KEY = "editor.wysiwyg.portal-web.docroot.html.portlet.blogs.edit_entry.jsp";
%>
